3.5 \(\int \frac{(d+e x) (a+b \log (c x^n))}{x} \, dx\)

Optimal. Leaf size=44 \[ \frac{d \left (a+b \log \left (c x^n\right )\right )^2}{2 b n}+a e x+b e x \log \left (c x^n\right )-b e n x \]

[Out]

a*e*x - b*e*n*x + b*e*x*Log[c*x^n] + (d*(a + b*Log[c*x^n])^2)/(2*b*n)

________________________________________________________________________________________

Rubi [A]  time = 0.0489701, antiderivative size = 44, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 19, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.158, Rules used = {2346, 2301, 2295} \[ \frac{d \left (a+b \log \left (c x^n\right )\right )^2}{2 b n}+a e x+b e x \log \left (c x^n\right )-b e n x \]

Antiderivative was successfully verified.

[In]

Int[((d + e*x)*(a + b*Log[c*x^n]))/x,x]

[Out]

a*e*x - b*e*n*x + b*e*x*Log[c*x^n] + (d*(a + b*Log[c*x^n])^2)/(2*b*n)

Rule 2346

Int[(((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_) + (e_.)*(x_))^(q_.))/(x_), x_Symbol] :> Dist[d, Int[((d
 + e*x)^(q - 1)*(a + b*Log[c*x^n])^p)/x, x], x] + Dist[e, Int[(d + e*x)^(q - 1)*(a + b*Log[c*x^n])^p, x], x] /
; FreeQ[{a, b, c, d, e, n}, x] && IGtQ[p, 0] && GtQ[q, 0] && IntegerQ[2*q]

Rule 2301

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))/(x_), x_Symbol] :> Simp[(a + b*Log[c*x^n])^2/(2*b*n), x] /; FreeQ[{a
, b, c, n}, x]

Rule 2295

Int[Log[(c_.)*(x_)^(n_.)], x_Symbol] :> Simp[x*Log[c*x^n], x] - Simp[n*x, x] /; FreeQ[{c, n}, x]

Rubi steps

\begin{align*} \int \frac{(d+e x) \left (a+b \log \left (c x^n\right )\right )}{x} \, dx &=d \int \frac{a+b \log \left (c x^n\right )}{x} \, dx+e \int \left (a+b \log \left (c x^n\right )\right ) \, dx\\ &=a e x+\frac{d \left (a+b \log \left (c x^n\right )\right )^2}{2 b n}+(b e) \int \log \left (c x^n\right ) \, dx\\ &=a e x-b e n x+b e x \log \left (c x^n\right )+\frac{d \left (a+b \log \left (c x^n\right )\right )^2}{2 b n}\\ \end{align*}

Mathematica [A]  time = 0.001957, size = 43, normalized size = 0.98 \[ a d \log (x)+a e x+\frac{b d \log ^2\left (c x^n\right )}{2 n}+b e x \log \left (c x^n\right )-b e n x \]

Antiderivative was successfully verified.

[In]

Integrate[((d + e*x)*(a + b*Log[c*x^n]))/x,x]

[Out]

a*e*x - b*e*n*x + a*d*Log[x] + b*e*x*Log[c*x^n] + (b*d*Log[c*x^n]^2)/(2*n)

________________________________________________________________________________________

Maple [A]  time = 0.06, size = 46, normalized size = 1.1 \begin{align*} \ln \left ( x \right ) ad+aex+bex\ln \left ( c{{\rm e}^{n\ln \left ( x \right ) }} \right ) +{\frac{bd \left ( \ln \left ( c{{\rm e}^{n\ln \left ( x \right ) }} \right ) \right ) ^{2}}{2\,n}}-benx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)*(a+b*ln(c*x^n))/x,x)

[Out]

ln(x)*a*d+a*e*x+b*e*x*ln(c*exp(n*ln(x)))+1/2*b*d/n*ln(c*exp(n*ln(x)))^2-b*e*n*x

________________________________________________________________________________________

Maxima [A]  time = 1.08083, size = 55, normalized size = 1.25 \begin{align*} -b e n x + b e x \log \left (c x^{n}\right ) + a e x + \frac{b d \log \left (c x^{n}\right )^{2}}{2 \, n} + a d \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*log(c*x^n))/x,x, algorithm="maxima")

[Out]

-b*e*n*x + b*e*x*log(c*x^n) + a*e*x + 1/2*b*d*log(c*x^n)^2/n + a*d*log(x)

________________________________________________________________________________________

Fricas [A]  time = 1.00115, size = 123, normalized size = 2.8 \begin{align*} \frac{1}{2} \, b d n \log \left (x\right )^{2} + b e x \log \left (c\right ) -{\left (b e n - a e\right )} x +{\left (b e n x + b d \log \left (c\right ) + a d\right )} \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*log(c*x^n))/x,x, algorithm="fricas")

[Out]

1/2*b*d*n*log(x)^2 + b*e*x*log(c) - (b*e*n - a*e)*x + (b*e*n*x + b*d*log(c) + a*d)*log(x)

________________________________________________________________________________________

Sympy [A]  time = 2.85682, size = 58, normalized size = 1.32 \begin{align*} a d \log{\left (x \right )} + a e x + \frac{b d n \log{\left (x \right )}^{2}}{2} + b d \log{\left (c \right )} \log{\left (x \right )} + b e n x \log{\left (x \right )} - b e n x + b e x \log{\left (c \right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*ln(c*x**n))/x,x)

[Out]

a*d*log(x) + a*e*x + b*d*n*log(x)**2/2 + b*d*log(c)*log(x) + b*e*n*x*log(x) - b*e*n*x + b*e*x*log(c)

________________________________________________________________________________________

Giac [A]  time = 1.28203, size = 66, normalized size = 1.5 \begin{align*} b n x e \log \left (x\right ) + \frac{1}{2} \, b d n \log \left (x\right )^{2} - b n x e + b x e \log \left (c\right ) + b d \log \left (c\right ) \log \left (x\right ) + a x e + a d \log \left (x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)*(a+b*log(c*x^n))/x,x, algorithm="giac")

[Out]

b*n*x*e*log(x) + 1/2*b*d*n*log(x)^2 - b*n*x*e + b*x*e*log(c) + b*d*log(c)*log(x) + a*x*e + a*d*log(x)